<template>
  <div class="layout">
    <!-- 二级路由出口 -->
    <router-view></router-view>

    <!-- 底部栏 -->
    <!-- placeholder 生成等高盒子，避免遮挡上方标准流 -->
    <van-tabbar v-model="active" route placeholder>
      <van-tabbar-item name="home" to='/home' icon="home-o">首页</van-tabbar-item>
      <van-tabbar-item name="search" to='/qa' icon="chat-o">问答</van-tabbar-item>
      <van-tabbar-item name="friends" to='/movie' icon="tv-o">视频</van-tabbar-item>
      <van-tabbar-item name="setting" to='/user' icon="user-o">用户</van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script>
export default {

    name:'layout',
    data() {
        return {
            active:0
        }
    },
  
}
</script>

<style></style>
